package com.booza.dao;

import java.util.Collection;

import com.booza.model.GameType;

/**
 * The DAO interface for games.
 */
public interface GameDAO
{
	/**
	 * Creates new game type.
	 * 
	 * @param game
	 *          - row to be inserted
	 */
	void createGameType(GameType game);

	/**
	 * Finds list of all games in games table.
	 * 
	 * @return list of games
	 */
	Collection<GameType> fetchGames();

	/**
	 * Find game by game name.
	 * 
	 * @param name
	 *          - game name to search for
	 * @return matching game details
	 */
	GameType fetchGameByName(String name);

	/**
	 * Find game by game id.
	 * 
	 * @param id
	 *          -game id to search for
	 * @return matching game details
	 */
	GameType fetchGameById(Integer id);

	/**
	 * Updates the game details.
	 * 
	 * @param game
	 *          -row to be updated
	 */
	void updateGameType(GameType game);
}
